const url =
  '?name=feizhu&from=alibaba&job=frontend&extraInfo=%7B%22a%22%3A%22b%22%2C%22c%22%3A%22d%22%7D&china=%E4%B8%AD%E5%9B%BD#id';
let newUrl = url.slice(1).slice(0, url.indexOf('#') - 1);
let arr = newUrl.split('&');
let objet = {};
arr.forEach((item) => {
  let val = item.split('=');
  let value = decodeURIComponent(val[1]);
  objet[val[0]] = value;
});
console.log(objet);
